<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>會員資料維護</title>
        <script src="/playdoll/scripts/jquery-1.11.0.min.js"></script>
        <style type="text/css">
            .Header { text-align:right; font-weight:bold; }
            #ProductList td { padding:10px; }
        </style>
        <script type="text/javascript">
            $(document).ready(function() {
                if (${member["sex"]} === true) {
                    $("#MaleSex").attr("checked", "checked");
                }
                else {
                    $("#FemaleSex").attr("checked", "checked");
                }
            });

        </script>

    </head>
    <body>
        <h1 align="center">會員資料維護</h1>        
    <center>
        <form id="form1" action="updatememberprocess" method="post">
            <table  Cellspacing=15 id="VIP" border="0" >
                <tr>
                    <td class="Header">會員編號：</td>
                    <td ><input id="id" name="id" type="text" value="${member["id"]}" readonly="readonly" /></td>
                </tr>

                <tr>
                    <td class="Header">帳號：</td>
                    <td  ><input id="Account" name="Account" type="text" value="${member["account"]}" /></td>
                </tr>

                <tr>
                    <td class="Header">密碼：</td>
                    <td ><input id="Password" name="Password" type="text" value="${member["password"]}" /></td>
                </tr>					

                <tr>
                    <td class="Header">生日：</td>
                    <td ><input type="Birth" id="Birth" name="Birth" value="${member["birth"]}"></td>				
                </tr>

                <tr>
                    <td class="Header">姓名：</td>
                    <td ><input id="Name" name="Name" type="text" value="${member["name"]}" /></td>
                </tr>	
                <tr>
                    <td class="Header">聯絡電話：</td>
                    <td ><input id="Phone" name="Phone" type="text" value="${member["phone"]}" /></td>
                </tr>	

                <tr>	
                    <td class="Header">聯絡地址：</td>
                    <td><input id="Address" name="Address" type="text" value="${member["address"]}" size="45"/></td>
                </tr>

                <tr>		
                    <td class="Header">性別：</td>
                    <td>
                        <input id="MaleSex" name="Sex" type="radio" value="1" />男生 
                        <input id="FemaleSex" name="Sex" type="radio" value="0" />女生
                    </td>				
                </tr>

                <tr>
                    <td class="Header">電子郵件：</td>
                    <td ><input id="Email" name="Email" type="text" value="${member["mail"]}" /></td>
                </tr>

                <tr>		
                    <td>&nbsp</td>
                    <td><input id="Submit1" type="submit" value="修改會員資料" />
                        <input id="Reset1" type="reset" value="查詢購物紀錄" /></td>
                    ${message}
                </tr>

            </table>
        </form>
    </center>
</body>
</html>
